export interface ResponseData {
  code: number
  msg: string
  success: boolean
}
//职位数据类型
export interface RoleData {
  roleId?: number
  createTime?: string
  updateTime?: string
  roleName: string
  remark?: string
  roleSort?: number
  roleKey?: string
}

//全部职位的数组的ts类型
export type Records = RoleData[]
//全部职位数据的相应的ts类型
export interface RoleResponseData extends ResponseData {
  data: {
    records: Records
    total: number
    size: number
    current: number
    orders: []
    optimizeCountSql: boolean
    hitCount: boolean
    countId: null
    maxLimit: null
    searchCount: boolean
    pages: number
  }
}

//菜单与按钮数据的ts类型
export interface MunuData {
  menuId: number
  remark: string
  parentId: number
  menuName: string
  orderNum: number
  component: string
  path: string
  query: string
  menuType: string
  perms: string
  icon: string
  visible: string
  isFrame: number
  isCache: number
  children?: MenuList
  checked: boolean
}
export type MenuList = MunuData[]

//菜单权限与按钮权限数据的ts类型
export interface MenuResponseData extends ResponseData {
  data: MenuList
}

//给职位分配菜单接口携带参数的ts类型
export interface SetRoleMenuData {
  menuId: number[]
  roleId: number
}
